package com.zzs.elm.service;

import java.util.List;

import com.zzs.elm.dao.DeliveryAddressDao;
import com.zzs.elm.po.DeliveryAddress;

public class DeliveryAddressService {
	
	private DeliveryAddressDao deliveryAddressDao = new DeliveryAddressDao();
	
	public List<DeliveryAddress> listDeliveryAddressByUserId(String userId) throws Exception {
		return deliveryAddressDao.listDeliveryAddressByUserId(userId);
	}
	
	public int saveDeliveryAddress(DeliveryAddress deliveryAddress) throws Exception {
		return deliveryAddressDao.saveDeliveryAddress(deliveryAddress);
	}
	
	public DeliveryAddress getDeliveryAddressById(Integer daId) throws Exception {
		return deliveryAddressDao.getDeliveryAddressById(daId);
	}
	
	public int updateDeliveryAddress(DeliveryAddress deliveryAddress) throws Exception {
		return deliveryAddressDao.updateDeliveryAddress(deliveryAddress);
	}
	
	public int removeDeliveryAddress(Integer daId) throws Exception {
		return deliveryAddressDao.removeDeliveryAddress(daId);
	}
	
}
